﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Elentok.Common.Wpf.Demos.ViewModels
{
  public interface IDemoViewModel
  {
    string Header { get; }
  }

  public abstract class DemoViewModel : ViewModelBase, IDemoViewModel
  {
    protected DemoViewModel(string header)
    {
      this.Header = header;
    }

    private string header;

    /// <summary>
    /// Gets or sets the header
    /// </summary>
    public string Header
    {
      get
      {
        return this.header;
      }
      protected set
      {
        if (this.header == value)
          return;

        OnPropertyChanging("Header");
        this.header = value;
        OnPropertyChanged("Header");
      }
    }
  }
}
